The Web4Ham.ini setup file

This file should be kept in the same directory than the WWW server program. All necessary initialization is done in this file.

The [INIT] section


[INIT]
DataDir		= c:\www\others\world
LogFile 	= .\web4ham.log
ErrFiles	= .\weber
Debug   	= 0
Iconic     	= 0
Logall		= 0
HTTPort 	= 80
RxTimeout       = 10

DATADIR This is the default data directory if no match is found in the hostlists. Place your WWW documents in this directory (and in the subdirectories of the data directory). LOGFILE is the filename of the logfile. You better specify the full path to it. ERRFILES is the path to the error files (prefix of filename). you may change the name to any name with less than six characters. The server relies on a complete set of files containing the error messages (e.g. WEBER200.HTM, WEBER201.HTM,...) The extension .HTM is mandatory. DEBUG you should set it to zero, I needed it for debugging in this alpha version. ICONIC =1 : if the server will start without opening a window. =0 : to show client requests in a window LOGALL =0 : show first line of request only =1 : show all lines sent by client HTTPort the listening port of the server (default: 80) RxTimeout next packet from client must arrive within xx seconds

The PROGRAMS section

[PROGRAMS]
NAME.SH=C:\WINSOCK\WWW\WEB2PDX.EXE NAME
URL.SH =C:\WINSOCK\WWW\WEB2PDX.EXE URL
The left hand side is the name of a specific search engine. The extension .SH is mandatory for a search engine. The right hand side gives the path to the program which will be executed by the server (and an optional argument (NAME or URL in our example). There is more information about Web2pdx available.

The Netmasks Section


; keep this order: special hosts first!
[255.255.255.255]
; dedicated hosts with full ip address
127.0.0.1       = c:\www
134.100.9.166   = c:\www

[255.255.255.0]
;other hosts in the following subnets
134.100.9  	= c:\www\friends
134.100.8	= c:\www\friends

[255.255.0.0]
;other class B domains
134.100  	= c:\www\others

[255.0.0.0]
44.0    	= c:\www\others\ampr

; hosts not in this section will have access to the default directory
specified by the variable "DataDir"

All directories must be considered as root directories for the specified hosts, e.g. if a host has access to the directory C:\WWW, he can access files in subdirectories of C:\WWW as well, but he cannot access a file in C:\ or C:\OTHER.

NEVER PUT COPYRIGHTED SOFTWARE OR PROTECTED DATA INTO THE DATA DIRECTORY! EVEN IF NO URL POINTS TO THE FILES, THEY CAN BE ACCESSED BY MALICIOUS CLIENTS!

Do not reorder the entries in brackets, they will always be scanned in this order. As the first matching entry will be allowed, do it the following way:

localhost and trusted hosts (in your domain) have access to the root data dir, next come the hosts of certain class B domains, last are the hosts of certain class A domains.

No other netmasks than these three are allowed. Hosts not appearing in the list will only have access to the default directory specified in the [INIT] section as DATADIR.

Do not use host names or domain names, the server does not make use of DNS calls, as it was developed at home where no DNS access is available. This is the reason why you will find only IP numbers in the log file.

Remarks

The way we are handling root directories might be not conforming to the HTTP protocol, because the same URL will point to different locations for different hosts. If we take the following URL
http://my.domain.de/home.htm
it might be expanded to
C:/WWW/FRIENDS/HOME.HTM  or to
C:/WWW/OTHERS/HOME.HTM
depending on the entries in the [255...] sections.

The [SUFFIXES] section


[SUFFIXES]
HTM=text/html
PS =text/postscript
TXT=text/plain
DOC=text/msword
RTF=text/rtf

If the query is done from a HTTP/1.0 client, the MIME contents type will be returned in the response. The contents type is based on the suffix of the file (left of the '=' sign) and the MIME type of the string following the equal sign in the [SUFFIXES] section. You might add further types if necessary.

The server does not recognize whether the client has the ability to view just a specific type and thus sends the file without converting it to another format.

If you know about Windows DLLs who can do file type conversion, please mail me the location of the archives and the names of the files.